@waline/client 1.3.11 → 1.5.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/Waline.min.d.ts +26 -8
- package/dist/Waline.min.js +1 -1
- package/dist/Waline.min.js.map +1 -1
- package/dist/Waline.noStyle.d.ts +26 -8
- package/dist/Waline.noStyle.js +1 -1
- package/dist/Waline.noStyle.js.map +1 -1
- package/dist/index.html +2 -1
- package/package.json +6 -6
- package/dist/Waline.commonjs.min.js +0 -13676
- package/dist/Waline.commonjs.min.js.LICENSE.txt +0 -5
- package/dist/Waline.commonjs.min.js.map +0 -1
- package/dist/Waline.min.js.LICENSE.txt +0 -5
- package/dist/Waline.noStyle.js.LICENSE.txt +0 -5
- package/dist/markdown.commonjs.min.js +0 -2870
- package/dist/markdown.commonjs.min.js.map +0 -1
- package/dist/markdown.min.js +0 -2870
- package/dist/markdown.min.js.map +0 -1
- package/dist/markdown.noStyle.js +0 -2870
- package/dist/markdown.noStyle.js.map +0 -1
- package/test/dist/main.js +0 -0
- package/test/dist/main.js.LICENSE.txt +0 -355
- package/test/node_modules/.package-lock.json +0 -36
- package/test/node_modules/comment-regex/index.js +0 -13
- package/test/node_modules/comment-regex/license +0 -21
- package/test/node_modules/comment-regex/package.json +0 -41
- package/test/node_modules/comment-regex/readme.md +0 -52
- package/test/node_modules/hanabi/LICENSE +0 -21
- package/test/node_modules/hanabi/README.md +0 -43
- package/test/node_modules/hanabi/dist/hanabi.js +0 -68
- package/test/node_modules/hanabi/dist/hanabi.min.js +0 -2
- package/test/node_modules/hanabi/dist/hanabi.min.js.map +0 -1
- package/test/node_modules/hanabi/package.json +0 -57
- package/test/node_modules/marked/LICENSE.md +0 -44
- package/test/node_modules/marked/README.md +0 -74
- package/test/node_modules/marked/bin/marked +0 -215
- package/test/node_modules/marked/lib/marked.esm.js +0 -2637
- package/test/node_modules/marked/lib/marked.js +0 -2787
- package/test/node_modules/marked/man/marked.1 +0 -111
- package/test/node_modules/marked/man/marked.1.txt +0 -96
- package/test/node_modules/marked/marked.min.js +0 -6
- package/test/node_modules/marked/package.json +0 -88
- package/test/node_modules/marked/src/Lexer.js +0 -491
- package/test/node_modules/marked/src/Parser.js +0 -263
- package/test/node_modules/marked/src/Renderer.js +0 -166
- package/test/node_modules/marked/src/Slugger.js +0 -49
- package/test/node_modules/marked/src/TextRenderer.js +0 -42
- package/test/node_modules/marked/src/Tokenizer.js +0 -730
- package/test/node_modules/marked/src/defaults.js +0 -32
- package/test/node_modules/marked/src/helpers.js +0 -260
- package/test/node_modules/marked/src/marked.js +0 -270
- package/test/node_modules/marked/src/rules.js +0 -310
package/dist/Waline.min.d.ts
CHANGED
|
@@ -11,13 +11,14 @@ interface CommentData {
|
|
|
11
11
|
}
|
|
12
12
|
interface Comment extends Exclude<CommentData, 'ua'> {
|
|
13
13
|
avatar?: string;
|
|
14
|
-
browser: string;
|
|
15
|
-
createAt: string;
|
|
16
|
-
insertAt: string;
|
|
17
|
-
updateAt: string;
|
|
18
14
|
objectId: string;
|
|
19
|
-
|
|
15
|
+
createdAt: string;
|
|
16
|
+
insertedAt: string;
|
|
17
|
+
updatedAt: string;
|
|
18
|
+
children: Comment[];
|
|
20
19
|
sticky?: boolean;
|
|
20
|
+
browser?: string;
|
|
21
|
+
os?: string;
|
|
21
22
|
}
|
|
22
23
|
|
|
23
24
|
interface RecentCommentsOptions {
|
|
@@ -36,12 +37,14 @@ interface Locale {
|
|
|
36
37
|
mail: string;
|
|
37
38
|
mailError: string;
|
|
38
39
|
link: string;
|
|
40
|
+
optional: string;
|
|
39
41
|
placeholder: string;
|
|
40
42
|
sofa: string;
|
|
41
43
|
submit: string;
|
|
42
44
|
reply: string;
|
|
43
45
|
cancelReply: string;
|
|
44
46
|
comment: string;
|
|
47
|
+
refresh: string;
|
|
45
48
|
more: string;
|
|
46
49
|
preview: string;
|
|
47
50
|
emoji: string;
|
|
@@ -58,6 +61,7 @@ interface Locale {
|
|
|
58
61
|
sticky: string;
|
|
59
62
|
word: string;
|
|
60
63
|
wordHint: string;
|
|
64
|
+
anonymous: string;
|
|
61
65
|
}
|
|
62
66
|
|
|
63
67
|
declare type Avatar = '' | 'mp' | 'identicon' | 'monsterid' | 'wavatar' | 'retro' | 'robohash' | 'hide';
|
|
@@ -102,6 +106,8 @@ interface EmojiInfo {
|
|
|
102
106
|
declare type EmojiMaps = Record<string, string>;
|
|
103
107
|
declare type Meta = 'nick' | 'mail' | 'link';
|
|
104
108
|
declare type UploadImage = (image: File) => Promise<string>;
|
|
109
|
+
declare type Highlighter = ((code: string, lang: string) => string) | ((code: string, lang: string, callback?: (error: unknown | undefined, code?: string) => void) => void);
|
|
110
|
+
declare type TexRenderer = (blockMode: boolean, tex: string) => string;
|
|
105
111
|
interface DeprecatedValineOptions {
|
|
106
112
|
/**
|
|
107
113
|
* @deprecated Use `locale.placeholder` instead, will be dropped in V2
|
|
@@ -209,6 +215,14 @@ interface DeprecatedValineOptions {
|
|
|
209
215
|
* @default 微博表情包
|
|
210
216
|
*/
|
|
211
217
|
emojiMaps?: EmojiMaps;
|
|
218
|
+
/**
|
|
219
|
+
* @deprecated Use `tex` instead
|
|
220
|
+
*
|
|
221
|
+
* 自定义 Tex 处理方法,用于预览。
|
|
222
|
+
*
|
|
223
|
+
* Custom math formula parse callback for preview.
|
|
224
|
+
*/
|
|
225
|
+
previewMath?: TexRenderer | false;
|
|
212
226
|
/**
|
|
213
227
|
* @deprecated Use `login` instead, will be dropped in V2
|
|
214
228
|
*
|
|
@@ -365,10 +379,8 @@ interface WalineOptions extends DeprecatedValineOptions {
|
|
|
365
379
|
* 代码高亮
|
|
366
380
|
*
|
|
367
381
|
* Code highlighting
|
|
368
|
-
*
|
|
369
|
-
* @default true
|
|
370
382
|
*/
|
|
371
|
-
highlight?:
|
|
383
|
+
highlight?: Highlighter | false;
|
|
372
384
|
/**
|
|
373
385
|
* 设置表情包
|
|
374
386
|
*
|
|
@@ -387,6 +399,12 @@ interface WalineOptions extends DeprecatedValineOptions {
|
|
|
387
399
|
* We will pass a picture file object when execute it.
|
|
388
400
|
*/
|
|
389
401
|
uploadImage?: UploadImage | false;
|
|
402
|
+
/**
|
|
403
|
+
* 自定义数学公式处理方法,用于预览。
|
|
404
|
+
*
|
|
405
|
+
* Custom math formula parse callback for preview.
|
|
406
|
+
*/
|
|
407
|
+
tex?: TexRenderer | false;
|
|
390
408
|
/**
|
|
391
409
|
*
|
|
392
410
|
* 登录模式状态,可选值:
|